<!-- 导航条 -->
<div class="bg-white bread-crumb">
    <ul class="breadcrumb b-a m-b-n-xs lter b-b wrapper-md">
        <li><a ui-sref="app.dashboard"><i class="fa fa-home"></i> 首页</a></li>
        <li class="active" ng-bind="title"></li>
        <button class="btn btn-sm btn-icon btn-default pull-right" ng-click="$state.reload()"><i
                class="icon icon-refresh"></i></button>
    </ul>
</div>
<div class="wrapper-sm">
    <div class="panel panel-default">
        <div class="panel-body">
            <form name="form" class="form-horizontal form-validation">
                <div class="form-group">
                    <label class="col-sm-2 control-label"><span class="text-danger wrapper-sm">*</span>旧密码</label>
                    <div class="col-sm-10">
                        <input type="password" ng-model="user.oldPassword" class="form-control w-md"
                               ng-maxlength="50" required>
                    </div>
                </div>
                <div class="line line-dashed b-b line-lg pull-in"></div>
                <div class="form-group">
                    <label class="col-sm-2 control-label"><span class="text-danger wrapper-sm">*</span>新密码</label>
                    <div class="col-sm-10">
                        <input type="password" ng-model="user.newPassword" name="newPassword" class="form-control w-md"
                               ui-validate=" '$value!=user.oldPassword' " ui-validate-watch=" 'user.oldPassword' "
                               ng-maxlength="50" ng-minlength="8" required>
                        <span class="help-block m-b-none" ng-show='form.newPassword.$error.validator'>新旧密码相同</span>
                    </div>
                </div>
                <div class="line line-dashed b-b line-lg pull-in"></div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">确认密码</label>
                    <div class="col-sm-10">
                        <input type="password" ng-model="user.confirmPassword" name="confirmPassword"
                               ui-validate=" '$value==user.newPassword' " ui-validate-watch=" 'user.newPassword' "
                               class="form-control w-md">
                        <span class="help-block m-b-none" ng-show='form.confirmPassword.$error.validator'>密码不匹配</span>
                    </div>
                </div>
                <div class="line line-dashed b-b line-lg pull-in"></div>
                <div class="form-group">
                    <div class="col-sm-4 col-sm-offset-2">
                        <button type="button" class="btn btn-default" ng-disabled="form.$invalid"
                                ng-click="saveData()">
                            保存
                        </button>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>